Florian Müllner [Thu, 1 Jun 2017 13:38:41 +0000 (15:38 +0200)]
overview: Don't expand workspace thumbnails by default
We currently expand the workspace switcher when workspaces are being
used, that is when there are any windows on a non-active workspace.
While this helps with the switcher's discoverability, it does eat into
the space available for window previews. By now the component should
be well established, so we can afford opting for space efficiency and
only expand the switcher while the user actually interacts with it.
Florian Müllner [Thu, 1 Jun 2017 13:49:46 +0000 (15:49 +0200)]
workspaceThumbnails: Reduce maximum thumbnail size
The overview's window picker is primarily about windows, and as the
previews that represent them are more effective the bigger they are,
it makes sense to scale down competing elements; start by reducing
the size of workspace thumbnails on the right ...
background: use of CHANGES_DONE_HINT events to avoid reloads
Instead of potentially loading a background mid-way when it changes, and
loading it again for every file monitor event, leverage
CHANGES_DONE_HINT events, which allow us to ignore CREATED and CHANGED
signals from the file monitor.
Carlos Garnacho [Sun, 23 Jul 2017 11:51:11 +0000 (13:51 +0200)]
keyboard: Only rebuild keyboard actor on keyboard type changes
About every other situation can do with synchronizing keyboard visibility,
and keyboard layout changes are already handled internally in the Keyboard
object.
A downside of this approach is that once created, there will always be a
Keyboard instance and its full actor hierarchy. Seems reasonable to do that
since we can't tell it won't ever be needed.
workspace: Switch back to using the :has-pointer property
In case where a method- and property name overlap, using the method
is less unambiguous than I thought - mozjs52-based gjs will only see
the method, while mozjs38-based gjs will only see the property. We
are in luck though, and the real property name contains dashes that
allow us to refer to the property in a way that works for all gjs
versions.
Florian Müllner [Thu, 25 May 2017 00:16:27 +0000 (02:16 +0200)]
build: Support the meson build system
Meson is on track to replace autotools as the build system of choice,
so support it in addition to autotools. If all goes well, we'll
eventually be able to drop the latter ...
Florian Müllner [Sun, 28 May 2017 19:46:02 +0000 (21:46 +0200)]
docs: Use entity for version
Meson's gtk-doc support currently requires the main SGML/XML file
to be located in the srcdir, so instead of substituting the module
version in that file directly, use a small auxiliary file that's
included via a custom entity.
Florian Müllner [Thu, 25 May 2017 16:28:03 +0000 (18:28 +0200)]
build: Move gvc submodule to /subprojects/gvc
When using the meson build system, gvc will be built as a subproject.
As meson restricts submodules to a subprojects/ directory in the
source tree root, move the submodule there.
workspace: Use has_pointer() method instead of property
ClutterActor has both a has_pointer() method and a :has-pointer
property (that we represent as 'has_pointer'). So far gjs was
able to deal with the name overlap, but now trying to use the
property will instead test for the availability of the method.
Just avoid the conflict by switching to the method, which is
unambiguous.
We now cancel animations on override, however we also want to cancel
animations altogether on unmap (that is, when hiding the overview)
to avoid icons swarming into the void.
Carlos Soriano [Fri, 5 Sep 2014 17:33:37 +0000 (19:33 +0200)]
iconGrid: Remove clones on new animation
Until now we were waiting the animation to complete to allow the user to
make a new animation. This could bring some problems and annoy nervous
users.
Instead of that, destroy clones on new animations triggers and
create a new animation with the new direction.
Florian Müllner [Fri, 2 Jun 2017 02:22:36 +0000 (04:22 +0200)]
appDisplay: Use ::paint handler to set up spring animation
The animation needs the icons' final positions, so we currently defer
it to a ::notify::allocation handler; however as starting the animation
during an allocation cycle would trigger a Clutter warning, it is
further deferred to a MetaLater. While this usually works, it is possible
that the allocation is already valid when we connect the signal, in which
case the animation is triggered at a later unexpected time. Switch to
a more robust ::paint handler instead, which also allows us to get rid
of the double-delay.
Any symbols (including class properties) that should be visible
outside the module it's defined in need to be defined as global.
For now gjs still allows the access for 'const', but get rid of
the warnings spill now by changing it.
main: Define global properties with 'var' instead of 'let'
Symbols that are defined with 'let' are no longer visible outside
the module that defines them. To unbreak the code base, define all
non-private properties as global.
The first time that the session is started, it can happen that the
AT SPI hasn't been correctly initialized, and this results in a crash
when attempting to register the caret or focus listeners.
In order to avoid this, these changes check the result of initializing
the AT SPI, to allow further attempts when it has failed.
Carlos Garnacho [Wed, 5 Jul 2017 22:05:22 +0000 (00:05 +0200)]
padOsd: Implement edition of actions for rings/strips
Customization of keycombo actions for strips/rings was lost in the
porting to new incarnation of Wacom support.
The UI here is slightly different, instead of requiring the user to
rotate/swipe in each direction to map each keycombo, the UI will
navigate the user through edition of both options, first one, then
the other.
Commit 39a840e2c3d added an additional parameter to shell_app_launch().
When adjusting callers, the parameter was also added accidentally to
calls of the confusingly similar g_app_info_launch() ...
Remove those to fix some warnings.
Florian Müllner [Wed, 17 May 2017 22:03:28 +0000 (00:03 +0200)]
extensionSystem: Handle all initExtension() extension errors
The method currently catches errors that occur when calling the
extension's init() method, but throws itself an error if the
expected extension.js file is missing. The former is pointless
if we expect all callers to handle errors themselves anyway, and
we should avoid the latter if we don't - opt for the second option
and handle a missing extension.js file gracefully.
Florian Müllner [Wed, 17 May 2017 21:57:18 +0000 (23:57 +0200)]
extensionSystem: Catch import errors
While we catch errors that occur when calling init(), enable() or
disable(), the import itself can throw an exception, for instance
if the extension imports an unavailable typelib or tries to draw
in a conflicting library.
Both reloadExtensions() and enableExtensions() are already expected
to catch extension errors. If they don't, this is the bug that
should be fixed instead of catching unhandled exceptions in the
caller.
Those will go away when we port authentication prompts to the new
MessageDialogContent widget, so pick the style classes from there
and adjust individual properties with more specific rules to re-
produce the existing style.
Carlos Garnacho [Thu, 19 Jan 2017 18:49:52 +0000 (19:49 +0100)]
ui: Refactor modal dialog into separate Dialog class
This is the basic dialog actor implementation, which will allow us to
use the same implementation on the session-global modal dialogs. The
ModalDialog class now uses it underneath, and so do all users of it.
Carlos Garnacho [Fri, 14 Jul 2017 20:23:53 +0000 (22:23 +0200)]
layout: Allow adding already parented actors for chrome tracking
let trackChrome accept actors that are not children of chrome actors.
this will be useful for the MetaCloseDialog in gnome-shell, which
is already included in the MetaWindowGroup, but needs to be tracked
as chrome for the dialog to receive pointer events on X11.
Carlos Garnacho [Fri, 14 Jul 2017 23:24:40 +0000 (01:24 +0200)]
slider: Cache slider width for dragging handlers
The actor allocation will be invalid on CLUTTER_TOUCH_BEGIN, because
it comes together with a CLUTTER_ENTER event that will recalculate
styles, and queue a relayout in result.
The net result is that on CLUTTER_TOUCH_BEGIN, the relayout has been
already queued, so the slider width comes up as 0, and the value ends
up as 1. Later touch events already happen on a validated actor, so
it is corrected. Still, not fun when modifying the volume slider on a
touchscreen.
gnome-shell: Make search result description semitransparent
There is a clear difference between the file name and its associated
description which the mockups clearly highlight. Consequently,
make the description label semitransparent, in order to emphasize
the file name, not the description itself.
Having descriptions with multiple lines will clutter
the view and make it more confusing for the user. Apart
from that, it also makes the search result a lot bigger,
potentially losing general vertical alignment.
Rares Visalom [Tue, 27 Jun 2017 22:01:13 +0000 (01:01 +0300)]
search: Highlight search terms in description
The classes extending the SearchResult can now connect
to the 'terms-changed' signal emitted by the SearchResult
class. This signal enables each object to update its
internal description in order to apply the bold style
onto strings that match the search terms.
Rares Visalom [Tue, 27 Jun 2017 21:58:07 +0000 (00:58 +0300)]
search: Propagate searchResults down the hierarchy
In order to prepare for applying the bold style to the part
of the description that matches the search terms, we need
to listen for the signal that announces the fact that the
search terms have changed. Given the fact that the
SearchResults class is aware of the changes regarding the
search terms, the classes that extent SearchResult need
to have a reference to it in order to listen for the
to-be-implemented 'terms-changed' signal.
Rares Visalom [Fri, 23 Jun 2017 14:24:34 +0000 (17:24 +0300)]
search: Increase maximum number of visible list search results
Since results are now much more concise and take up less
space, we can use the 'saved' space to provide the user
with more search results for each provider.
gnome-shell: Use standard font size for the search-result-title class
The current size of the text is way bigger than what
we want now. The default front size is what we are
looking after, therefore no explicit value is needed
to specify the font size.
search: Replace the gradient separator with a simple line
The current separator uses a gradient effect as a separator
between search results. As the mockups suggest, the gradient
separator is no longer needed, in favor of a more simple one,
which is a thin semitransparent line.
In order to match the current mockups, the providerIcon
class needed to include both the name of the provider
and the label that informs the user about how many more
search results are available for that specific provider.
The latter replaces the plus sign icon that has been
used so far.
Rares Visalom [Tue, 20 Jun 2017 19:13:48 +0000 (22:13 +0300)]
search: Make the results take more horizontal space
In order to make gnome-shell search functionality fit on
smaller screens, like those of devices, search results
need to take advantage of more horizontal space so that
any extra space can be used efficiently.
In order to do so, change the layout of the ListSearchResult
class from a vertical one, to a horizontal one and also
decrease the padding of the list-search-result-content css
class.
Carlos Garnacho [Wed, 12 Jul 2017 20:38:31 +0000 (22:38 +0200)]
padOsd: strengthen ring/strip label creation
If the padOsd is given a nonexistent ring/strip, things would fail
badly later when trying to paint a 0x0 StLabel. Just avoid creating
more ring/strip labels than those known by libwacom.
This is unlikely to happen, but seems better to protect against it.
ui: Reset workspace thumbnail porthole on monitor changes
The porthole will not be destroyed when the scale factor changed.
That makes workspace thumbnail porthole still wrong size in the first
seeing after the scale factor changed.
Jonas Ådahl [Wed, 7 Jun 2017 06:53:25 +0000 (14:53 +0800)]
shell-util: Fix capturing scaled views
libmutter-clutter fixed stage capturing when views are scaled, and for
that to work properly when compositing the screenshot, we need to deal
with the cairo device scale here too.
Florian Müllner [Sat, 17 Jun 2017 16:14:20 +0000 (18:14 +0200)]
dateMenu: Set _delegate on non-menu-item menu child
PopupMenu needs special-treatment of certain types of menu items,
which it determines via children's _delegate property. However as
the calendar drop-down is very unmenu-ish, we use regular actors
rather than PopupMenuItems and the missing _delegate property
triggers a warning. Just add it as the bare minimum to make
PopupMenu happy.
Florian Müllner [Tue, 13 Jun 2017 03:51:31 +0000 (05:51 +0200)]
windowManager: Fix a warning
The destroy effect currently relies on a monkey-patched property
added from the map effect. However on X11 it is possible that we
did no map animation for a window that is destroyed when the shell
was restarted or had taken over from another WM. Just use the real
MetaWindow property to avoid a warning in that case.
layout: Skip strut computation in the no-monitor case
It's possible for updateRegions() to be called before monitors have
been properly initialized. Instead of throwing an error in that case,
just skip the strut computation (that doesn't make sense anyway without
a monitor).